{extend name='admin@public/content'}

{block name="button"}
{if auth("$classuri/add")}
<button data-modal='{:url("$classuri/add")}' data-title="新增" class='layui-btn layui-btn-sm layui-btn-primary'>新增体检报告</button>
{/if}

{if auth("$classuri/add")}
<button data-modal='{:url("$classuri/import")}' data-title="批量导入" class='layui-btn layui-btn-sm layui-btn-primary'>批量导入</button>
{/if}
{/block}

{block name="content"}
<!-- 表单搜索 开始 -->
<form class="layui-form layui-form-pane form-search" action="{:request()->url()}" onsubmit="return false" method="get">

    <div class="layui-form-item layui-inline">
        <label class="layui-form-label">手机号码</label>
        <div class="layui-input-inline">
            <input name="mobile" value="{$Think.get.mobile}" placeholder="输入手机号码" class="layui-input">
        </div>
    </div>

    <div class="layui-form-item layui-inline">
        <label class="layui-form-label">订单号</label>
        <div class="layui-input-inline">
            <input name="order_sn" value="{$Think.get.order_sn}" placeholder="输入订单号" class="layui-input">
        </div>
    </div>

    <div class="layui-form-item layui-inline">
        <button class="layui-btn layui-btn-primary"><i class="layui-icon">&#xe615;</i> 搜 索</button>
    </div>

</form>
<!-- 表单搜索 结束 -->

<form onsubmit="return false;" data-auto="" method="POST">
    <input type="hidden" value="resort" name="action">
    <table class="layui-table notevent" lay-skin="line">
        <thead>
            <tr>
                <th class='list-table-check-td'>
                    <input data-none-auto="" data-check-target='.list-check-box' type='checkbox'/>
                </th>
                <th class='text-left w50'>ID</th>
                <th class='text-left w150'>用户名</th>
                <th class='text-left w150'>手机号</th>
                <th class='text-left w300'>订单号</th>
                <th class='text-left'>报告地址</th>
                <th class='text-left w150'>提交时间</th>
                <th class='text-center w120'>操作</th>
            </tr>
        </thead>
        <tbody>
        	{if isset($list)}
            {foreach $list as $key=>$vo}
            <tr>
                <td class='list-table-check-td'>
                    <input class="list-check-box" value='{$vo.id}' type='checkbox'/>
                </td>
                <td class='text-center'>{$vo.id}</td>
                <td class='text-left'>{$vo.real_name}</td>
                <td class='text-left'>{$vo.mobile}</td>
                <td class='text-left'>{$vo.order_sn}</td>
                <td class='text-left'>{$vo.name}</td>
                <td class='text-left'>{$vo.create_time|date="Y-m-d H:i"}</td>
                <td class='text-center nowrap'>
                    {if auth("$classuri/edit")}
                    <a data-modal='{:url("$classuri/edit")}?id={$vo.id}' href="javascript:void(0)">编辑</a>
                    {/if}
                    {if auth("$classuri/cancel")}
                    <span class="text-explode">|</span>
                    <a data-update="{$vo.id}" data-field='delete' data-action='{:url("$classuri/cancel")}' href="javascript:void(0)">删除</a>
                    {/if}
                </td>
            </tr>
            {/foreach}
            {/if}
        </tbody>
    </table>
    {if isset($page)}<p>{$page|raw}</p>{/if}
</form>

<script>
    (function () {
        window.form.render();
    })();
</script>
{/block}